<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('修改活动')"/>
    <th:block th:include="include :: datetimepicker-css"/>
    <th:block th:include="include :: bootstrap-fileinput-css"/>
    <th:block th:include="include :: summernote-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal m" id="form-activity-edit" th:object="${cstActivity}">
        <input name="id" th:field="*{id}" type="hidden">
        <div class="form-group">
            <label class="col-sm-3 control-label">活动标题：</label>
            <div class="col-sm-8">
                <textarea name="title" class="form-control" readonly="readonly">[[*{title}]]</textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">活动简介：</label>
            <div class="col-sm-8">
                <textarea name="brief" class="form-control" readonly="readonly">[[*{brief}]]</textarea>
            </div>
        </div>
        54456
        <div class="form-group">
            <label class="col-sm-3 control-label">开始时间：</label>
            <div class="col-sm-8">
                <div class="input-group date">
                    <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                    <input name="startTime" th:value="${#dates.format(cstActivity.startTime, 'yyyy-MM-dd')}"
                           class="form-control" placeholder="yyyy-MM-dd" type="text" readonly="readonly">
                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">结束时间：</label>
            <div class="col-sm-8">
                <div class="input-group date">
                    <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                    <input name="endTime" th:value="${#dates.format(cstActivity.endTime, 'yyyy-MM-dd')}"
                           class="form-control" placeholder="yyyy-MM-dd" type="text" readonly="readonly">
                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系人：</label>
            <div class="col-sm-8">
                <input name="contacter" th:field="*{contacter}" class="form-control" type="text" readonly="readonly">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">活动地址：</label>
            <div class="col-sm-8">
                <textarea name="address" class="form-control" readonly="readonly">[[*{address}]]</textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">联系电话：</label>
            <div class="col-sm-8">
                <input name="phone" th:field="*{phone}" class="form-control" type="text" readonly="readonly">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">活动海报：</label>
            <div class="col-sm-8">
                <img th:src="${#httpServletRequest.getContextPath()}+*{images}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">是否通过：</label>
            <div class="col-sm-8">
                <div class="radio-box" th:each="dict : ${@dict.getType('sys_check_status')}">
                    <input type="radio" th:id="${'isCheck_' + dict.dictCode}" name="isCheck" th:value="${dict.dictValue}" th:field="*{isCheck}">
                    <label th:for="${'isCheck_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">不通过原因：</label>
            <div class="col-sm-8">
                <input name="checkCase" th:field="*{checkCase}" class="form-control" type="text">
            </div>
        </div>
        <!-- <div class="form-group">
             <label class="col-sm-3 control-label">现场签到审核人员：</label>
             <div class="col-sm-8">
                 <input name="mid" th:field="*{mid}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">发起支部：</label>
             <div class="col-sm-8">
                 <input name="groupName" th:field="*{groupName}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">发布时间：</label>
             <div class="col-sm-8">
                 <div class="input-group date">
                     <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                     <input name="publishTime" th:value="${#dates.format(cstActivity.publishTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
                 </div>
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">0普通类型：</label>
             <div class="col-sm-8">
                 <input name="tpe" th:field="*{tpe}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">0 无限制(人数限制）：</label>
             <div class="col-sm-8">
                 <input name="personLimit" th:field="*{personLimit}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">奖励规则ID：</label>
             <div class="col-sm-8">
                 <input name="eventCode" th:field="*{eventCode}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">图集：</label>
             <div class="col-sm-8">
                 <textarea name="photos" class="form-control">[[*{photos}]]</textarea>
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">是否已通知：</label>
             <div class="col-sm-8">
                 <input name="isNotify" th:field="*{isNotify}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">关联新闻的ID：</label>
             <div class="col-sm-8">
                 <textarea name="newsids" class="form-control">[[*{newsids}]]</textarea>
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">点击数：</label>
             <div class="col-sm-8">
                 <input name="clickCount" th:field="*{clickCount}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">点赞数：</label>
             <div class="col-sm-8">
                 <input name="likes" th:field="*{likes}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">0未上报，1已上报：</label>
             <div class="col-sm-8">
                 <input name="isReport" th:field="*{isReport}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">0 未审，1通过，2不通过：</label>
             <div class="col-sm-8">
                 <div class="radio-box" th:each="dict : ${@dict.getType('sys_check_status')}">
                     <input type="radio" th:id="${'isCheck_' + dict.dictCode}" name="isCheck" th:value="${dict.dictValue}" th:field="*{isCheck}">
                     <label th:for="${'isCheck_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                 </div>
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">不通过原因：</label>
             <div class="col-sm-8">
                 <input name="checkCase" th:field="*{checkCase}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">0 未审，1通过，2不通过：</label>
             <div class="col-sm-8">
                 <input name="checkTime" th:field="*{checkTime}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">审核人：</label>
             <div class="col-sm-8">
                 <input name="checkUser" th:field="*{checkUser}" class="form-control" type="text">
             </div>
         </div>
         <div class="form-group">
             <label class="col-sm-3 control-label">参与人数：</label>
             <div class="col-sm-8">
                 <input name="joincount" th:field="*{joincount}" class="form-control" type="text">
             </div>
         </div>-->
    </form>
</div>
<th:block th:include="include :: footer"/>
<th:block th:include="include :: datetimepicker-js"/>
<th:block th:include="include :: bootstrap-fileinput-js"/>
<th:block th:include="include :: summernote-js"/>
<script type="text/javascript">
    var prefix = ctx + "activity/activity";
    $("#form-activity-edit").validate({
        focusCleanup: true
    });

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/check", $('#form-activity-edit').serialize());
        }
    }
    $("input[name='publishTime']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });

    $("input[name='startTime']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });

    $("input[name='endTime']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });

    $("input[name='addTime']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });
</script>
</body>
</html>